/**
 * Candidate number: 35834
 */
package tv.starfu.components.physics;

import com.artemis.Component;
import com.jme3.bullet.collision.shapes.BoxCollisionShape;
import com.jme3.bullet.collision.shapes.CapsuleCollisionShape;
import com.jme3.bullet.collision.shapes.CollisionShape;
import com.jme3.bullet.collision.shapes.CylinderCollisionShape;
import com.jme3.bullet.collision.shapes.MeshCollisionShape;
import com.jme3.bullet.collision.shapes.PlaneCollisionShape;
import com.jme3.bullet.collision.shapes.SphereCollisionShape;

public class CollisionMesh extends Component {
    public CollisionShape mesh;
    
    public enum Shape { BOX, CAPSULE, SPHERE, PLANE, MESH, CYLINDER };
    
    public CollisionMesh() {
        
    }
    
    public void setShape(Shape s) {
        switch(s) {
            case BOX :
                mesh = new BoxCollisionShape();
                break;
            case CAPSULE :
                mesh = new CapsuleCollisionShape();
                break;
            case SPHERE :
                mesh = new SphereCollisionShape();
                break;
            case PLANE :
                mesh = new PlaneCollisionShape();
                break;
            case MESH :
                mesh = new MeshCollisionShape();
                break;
            case CYLINDER :
                mesh = new CylinderCollisionShape();
                break;
        }
    }
}
